import Vue from 'vue'
import './cube-ui'
import App from './App.vue'
import router from './router'
import store from './store'
import axios from 'axios'
import interceptor from './http-interecptor'
import LHeader from './components/Header.vue';
import {createAPI} from 'cube-ui';
import Notice from './components/Notice.vue';
import notice from '@/services/notice'; //用于自己创建的弹出方法

import BallAnim from './components/BallAnim.vue';

Vue.config.productionTip = false

//全局引入Header.vue
//LHeader 就是组件Header.vue导出的组件配置
Vue.component('l-header', LHeader)

//全局定义一个请求方法
Vue.prototype.$http = axios;

//自己创建的Notice服务
Vue.prototype.$notice = notice;

//创建$createNotice API
createAPI(Vue, Notice, true); //参数3 表示 单例
createAPI(Vue, BallAnim, ['transitionend']); //不传第三个参数即多实例，一定要考虑销毁

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
